﻿namespace Pay.DTO
{
	/// <summary>
	/// 基本数据
	/// </summary>
	public class BaseResultDto
	{
		/// <summary>
		/// 0正常、非0异常
		/// </summary>
		public int Code { get; set; }

		/// <summary>
		/// 消息
		/// </summary>
		public string Msg { get; set; }

		/// <summary>
		/// 成功
		/// </summary>
		public static BaseResultDto Success()
		{
			return new BaseResultDto();
		}

		/// <summary>
		/// 失败
		/// </summary>
		public static BaseResultDto Fail(string msg)
		{
			return new BaseResultDto { Code = 10000, Msg = msg };
		}
	}
}
